package appapi.Vo.brider;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author dhq
 * @version 1.0
 * @date 2023/9/13  20:17
 */
@Data
@ApiModel("工段详情")
public class SectionDetailVo implements Serializable {
    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value="工段Id")
    private Long sectId;
    @TableField(value="sect_name")
    @ApiModelProperty(value="工段名称")
    private String sectName;

    @TableField(value="sect_no")
    @ApiModelProperty(value="工段编号")
    private String sectNo;

    /**
     * 所属项目名称
     */
    @ApiModelProperty(value="所属项目名称")
    private String projName;

    @ApiModelProperty(value="工段Id")
    private Long projId;

    /**
     * 负责人
     */
    @ApiModelProperty(value="负责人")
    private String sectHead;

    /**
     * 联系电话
     */
    @ApiModelProperty(value="联系电话")
    @NotNull(message = "手机号码不能为空")
    @NotBlank(message = "手机号码不能为空")
    @Pattern(regexp = "\\d{11}", message = "手机号码必须为11位数字")
    @Length(min = 11,max = 32)
    private String sectTel;

    /**
     * 工期时间
     */
    @ApiModelProperty(value="工期时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime sectDuration;

    /**
     * 备注说明
     */
    @ApiModelProperty(value="备注说明")
    private String sectNote;












}
